package org.zht.dormpro.auth.bean;

import lombok.Getter;
import lombok.Setter;

import java.util.ArrayList;
import java.util.List;
import java.util.Map;

/**
 * 返回前台系统的tree
 * @param <T>
 */
public class Tree<T> {
    @Getter @Setter
    private Integer id;
    @Getter @Setter
    private String text;
    @Getter @Setter
    private Integer parentId;
    //节点的其他属性
    @Getter @Setter
    private Map<String,Object> attributes;
    @Getter @Setter
    private Map<String,Object> state;
    //节点的子节点
    @Getter @Setter
    private List<Tree<T>> children = new ArrayList<>();
    @Getter @Setter
    private boolean hasParent;
    @Getter @Setter
    private boolean hasChild;
    @Getter @Setter
    private boolean checked;
}
